<template>
    <div>
        <h1>Test Axios</h1>
        <el-button @click="ajax()">Trigger Ajax</el-button>
    </div>
</template>

<script>
    import axios from 'axios';
    export default {
        name: 'TestAxios',
        components: {

        },
        data: function() {
            return {
                visible: false
            }
        },
        methods: {
            ajax() {
                axios.get('http://localhost:8882/resource/valueRange?field=name', {
                    params: {
                        ID: 12345
                    }
                }).then(function (response) {
                    console.log(response);
                }).catch((error) => {
                    console.log(error);
                });
            }
        }
    }
</script>